package com.ruoyi.system.entity;
import cn.hutool.core.util.StrUtil;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.ruoyi.common.annotation.Excel;
import lombok.Data;
import java.util.Date;
import java.io.Serializable;

/**
 * 火灾报警(SysFirePoint)实体类
 * @since 2022-12-01 16:50:06
 */
@Data
public class SysFirePoint implements Serializable {
    private static final long serialVersionUID = 182697591628243433L;
    
    private Integer id;
    /**
     * 报警主机模块
     */
    @Excel(name = "报警主机模块")
    private String alarmHostModule;
    /**
     * 安装位置
     */
    @Excel(name = "安装位置")
    private String installAddress;
    /**
     * 位号
     */
    @Excel(name = "位号")
    private String bitNumber;
    /**
     * 状态
     */
    @Excel(name = "状态")
    private String state;

    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date createTime;

    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date updateTime;

    /**
     * 实时数据库值 1显示为正常，0显示为异常
     */
    private String av;

    public String getAv() {
        if (StrUtil.isEmpty(av)) {
            this.av = "0";
        }
        return av;
    }

}

